<!DOCTYPE html>
<html>
<head lang="en">
    <meta charset="UTF-8">
    <title>python web</title>
    <script type="text/javascript" src="/static/js/jquery/jquery.min.js"></script>
    <script type="text/javascript" src="{{ static_url('js/web_qq/10125/mq_comm.js') }}"></script>
    <script type="text/javascript" src="{{ static_url('js/web_qq/10125/mq.js') }}"></script>

    <script type="text/javascript">
        function GetRequest() {
            var url = location.search; //获取url中"?"符后的字串
            var Request = {};
            if (url.indexOf("?") != -1) {
                var str = url.substr(1);
                var params = str.split("&");
                for (var i = 0; i < params.length; i++) {
                    Request[params[i].split("=")[0]] = (params[i].split("=")[1]);
                }
            }
            return Request;
        }
        //alert('yyXuDoOMVzZ1r0O4yIS-D*jPubA0DsMz3*DFI4EQnFcOiA5xAQuyb4bsboFMvH6hPwEi*uX8Bi5uZUO-jLawSGGado9PkNE-wPWpZipgnvOln933dZyvpiJpwHudFq7Xme8fHlSoEaGee16uVKdkyMoriGOfQn99yBOtfz1UhLGEDP6zwntowp7aK5jvHtpbegeaeYflBDN71yIuCcBdPw__'.length);
    </script>
    <script type="text/javascript">
        u = function(x, K) {
            x += "";
            for (var N = [], T = 0; T < K.length; T++)
                N[T % 4] ^= K.charCodeAt(T);
            var U = ["EC", "OK"], V = [];
            V[0] = x >> 24 & 255 ^ U[0].charCodeAt(0);
            V[1] = x >> 16 & 255 ^ U[0].charCodeAt(1);
            V[2] = x >> 8 & 255 ^ U[1].charCodeAt(0);
            V[3] = x & 255 ^ U[1].charCodeAt(1);
            U = [];
            for (T = 0; T < 8; T++)
                U[T] = T % 2 == 0 ? N[T >> 1] : V[T >> 1];
            N = ["0", "1", "2", "3", "4", "5", "6", "7", "8", "9", "A", "B", "C", "D", "E", "F"];
            V = "";
            for (T = 0; T < U.length; T++) {
                V += N[U[T] >> 4 & 15];
                V += N[U[T] & 15]
            }
            return V
        };
        //参数形式为(uin, ptwebqq) 备注： QQ号码，ptwebqq（cookie获取）
        var bb = u('455091702', '2c290ae52f6390c2da94be0c0c4f439bfc68448d88d361010b039545f72d43cf');
//        alert(bb);
        $(document).ready(function () {
            //接收参数
            var Request = GetRequest();
            var password = Request['password'];
            var salt = Request['salt'];
            var verify_code = Request['verify_code'];
//            alert(Request['password']);
//            alert(Request['salt']);
//            alert(Request['verify_code']);
            //加密
            //var aa = getEncryption(password, salt, verify_code);
            //var aa = password;
            //alert(aa);
            $('#password').html(bb);
            //0C5E0D63096A04BD
            //结果完全正确
            //todo python 调用js 或者 这段js转为python
        });

    </script>
</head>
<body>
<div id="password"></div>
</body>
</html>